package com.ruanyun.modular.ry.api.web;

import cn.stylefeng.roses.core.reqres.response.ResponseData;
import com.ruanyun.modular.ry.service.AppVersionService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@CrossOrigin
@RestController
@RequestMapping("/api/appVersion")
public class ApiAppVersionController {

    @Autowired
    private AppVersionService appVersionService;

    /**
     * 版本升级
     *
     * @return
     */
    @PostMapping("/isUpgrade")
    public ResponseData isUpgrade() {
        return appVersionService.isUpgrade();
    }
}
